using LF.Shared.Dtos.Input;
using LF.Shared.Dtos.Out;
using Microsoft.AspNetCore.Mvc;

namespace LF.Application.Services
{
    public interface IDictService : IApplicationService
    {
        #region 字典类型管理
        /// <summary>
        /// 获取字典类型列表
        /// </summary>
        /// <param name="search">查询条件</param>
        /// <returns>字典类型列表</returns>
        Result<DictTypeSearchOut> List(DictTypeSearch search);

        /// <summary>
        /// 获取字典类型信息
        /// </summary>
        /// <param name="id">字典类型ID</param>
        /// <returns>字典类型信息</returns>
        Result<DictTypeOut> Info(Guid id);

        /// <summary>
        /// 创建或更新字典类型
        /// </summary>
        /// <param name="dictType">字典类型信息</param>
        /// <returns>操作结果</returns>
        Result Edit(DictTypeOut dictType);

        /// <summary>
        /// 删除字典类型
        /// </summary>
        /// <param name="id">字典类型ID</param>
        /// <returns>操作结果</returns>
        Result Delete(Guid id);

        /// <summary>
        /// 获取所有字典类型（用于下拉选择）
        /// </summary>
        /// <returns>所有字典类型</returns>
        Result<List<DictTypeOut>> GetAll();
        #endregion

        #region 字典项管理
        /// <summary>
        /// 获取字典项列表
        /// </summary>
        /// <param name="search">查询条件</param>
        /// <returns>字典项列表</returns>
        Result<DictItemSearchOut> DictItemList(DictItemSearch search);

        /// <summary>
        /// 获取字典项信息
        /// </summary>
        /// <param name="id">字典项ID</param>
        /// <returns>字典项信息</returns>
        Result<DictItemOut> DictItemInfo(Guid id);

        /// <summary>
        /// 创建或更新字典项
        /// </summary>
        /// <param name="dictItem">字典项信息</param>
        /// <returns>操作结果</returns>
        Result DictItemEdit(DictItemOut dictItem);

        /// <summary>
        /// 删除字典项
        /// </summary>
        /// <param name="id">字典项ID</param>
        /// <returns>操作结果</returns>
        Result DictItemDelete(Guid id);
        #endregion
    }
} 